<!DOCTYPE html>
<html>
<head>
<meta name="layout" content="main" />
<title>Welcome to Hotel Review</title>

</head>
<body>
	<div class="header">

		<h1 class="page-title">Welcome</h1>
		<ul class="breadcrumb">
			<li><a href="${createLink(uri: '/')}"><g:message
						code="default.home.label" /></a></li>
			<li class="active">Search Hotel</li>
		</ul>

	</div>
	<div class="main-content">

		<g:form class="form-horizontal" action="index">
			<div class="form-group">
				<label class="col-sm-2 control-label" for="parent"> Hotel </label>
				<div class="col-sm-8">
					<g:textField name="name" class="form-control" value="${params.name }" />

				</div>
				<div class="col-sm-2">*</div>
			</div>
			<div class="form-group">

				<div class="col-sm-2"></div>
				<div class="col-sm-8 center-block">
					<div class="center-block">
						<button type="submit" class="btn btn-primary">Search</button>
						<g:link controller="home" action="advanced"
							class="btn btn-primary">Advanced</g:link>
					</div>

				</div>
				<div class="col-sm-2"></div>

			</div>
		</g:form>
		<table class="table table-striped">
			<tbody>
				<g:each in="${hotelList}" var="hotelInstance">
					<tr>

						<td>
						<g:link controller="review" action="index" id="${hotelInstance?.id }">
							${fieldValue(bean: hotelInstance, field: "name")}
							</g:link>
						</td>

						

						<td>
							${fieldValue(bean: hotelInstance, field: "city")}<br>
							${fieldValue(bean: hotelInstance, field: "starRating")}
							
						</td>

						
					</tr>
				</g:each>
			</tbody>
		</table>
		<div class="pagination">
			<bootstrap:paginate total="${totalRecord}" params="[name:params.name]" />
		</div>

	</div>
</body>
</html>
